package com.neo.base.fileTest

import scala.io.Source

class OpenFileAndDeal {
  def OpenFile(filename: String): Unit ={

    for(line <- Source.fromFile(filename,"UTF-8").getLines()){
      println(line)
    }
  }
}


object OpenFileAndDeal{
  def main(args: Array[String]): Unit = {
    val filename ="D:\\root\\test\\scala\\IDC_httplog_456_20160729194333004.txt"


    val filed  = new OpenFileAndDeal
    filed.OpenFile(filename)
  }
}
